package com.program.houai.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;

/**
 * @version v1.0
 * @ProjectName: EOrder-master
 * @ClassName: BcmallOrderGoodsEntity
 * @Description: TODO(一句话描述该类的功能)
 * @Author: Topcheer
 * @Date: 2024/8/29 12:47
 */
@TableName("bcmall_order_goods")
@Data
@ApiModel(value ="订单明细",description = "订单明细")
public class CmallOrderGoodsEntity {

    @TableId(value = "id", type = IdType.AUTO)
    @ApiModelProperty(value = "主键")
    private int id;

    @ApiModelProperty(value = "订单主键")
    private int orderId;

    @ApiModelProperty(value = "商品名称")
    private String goodsName;

    @ApiModelProperty(value = "购买数量")
    private int number;

    @ApiModelProperty(value = "商品单价")
    private double price;

    @ApiModelProperty(value = "图片地址")
    private String picUrl;

    @ApiModelProperty(value = "添加时间")
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date addTime;

    @ApiModelProperty(value = "订单号")
    @TableField(exist = false)
    private String txnNo;

    @ApiModelProperty(name = "佣金(元)")
    @TableField(exist = false)
    private String royalty;

    @ApiModelProperty(value = "订单金额")
    @TableField(exist = false)
    private String ordrPrice;

    @TableLogic
    private int deleted;
}
